#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
int main()
{
	int a, d;
	float b, c;
	scanf("%d,%f", &a, &b); d = b;
	switch (a)
	{
	case 0: if (b <= 1)c = 10; else{ if (d == b)c = 3 * (d - 1) + 10; else c = 3 * (d)+10; }; break;
	case 1: if (b <= 1)c = 10; else{ if (d == b)c = 3 * (d - 1) + 10; else c = 3 * (d)+10; }; break;
	case 2:if (b <= 1)c = 15; else{ if (d == b)c = 5.0*(d - 1) + 15; else c = 5.0*(d)+15; }; break;
	case 3:if (b <= 1)c = 15; else{ if (d == b)c = 6.5*(d - 1) + 10; else c = 6.5*(d)+15; }; break;
	case 4:if (b <= 1)c = 15; else{ if (d == b)c = 10.0*(d - 1) + 15; else c = 10.0*(d)+15; }; break;
	
		printf("Error in Area\n", c);
	}
	printf("Price: %.2f\n", c);
	
	return 0;
}
